<?php
class Help extends MY_Controller {
    /**
    * Responsable for auto load the model
    * @return void
    */
   public function __construct(){
		parent::__construct();
   }
	
	function index(){
		$data = array();
		$slug = $this->uri->segment(2);
		$this->load->model('help_m', 'help');
		$help = $this->help->get_help_by_slug($slug);
		// echo $this->db->last_query();die;
		if(!$help)
			show_404();
		$data['page_content']	=	$help->content;
		$data['page_title']		=	$help->title;
		$data['content'] 			= 'help';
		$data['helps'][] 	= array(
			'title'	=>	'Hướng dẫn đăng ký',
			'help'	=>	$this->help->get_helps('dang_ky'));
		$data['helps'][]	= array(
			'title'	=>	'Hướng dẫn thanh toán',
			'help'	=>	$this->help->get_helps('thanh_toan'));
		$this->load->view('tpl/template', $data);
	}
 }